From 572649740e58d7c9cd5d42e732b8fbf6c93290f3 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Fri, 1 Jan 2021 10:14:01 -0500 Subject: [PATCH] docs: Flesh out the gtk4-builder-tool man page Add some details about the --3to4 conversion, and set expectations. --- docs/reference/gtk/gtk4-builder-tool.xml | 56 +++++++++++++----------- 1 file changed, 31 insertions(+), 25 deletions(-) diff --git a/docs/reference/gtk/gtk4-builder-tool.xml b/docs/reference/gtk/gtk4-builder-tool.xml index 992f2d9db1..c6c6d1ae70 100644 --- a/docs/reference/gtk/gtk4-builder-tool.xml +++ b/docs/reference/gtk/gtk4-builder-tool.xml @@ -41,35 +41,41 @@ gtk4-builder-tool can perform various operations on GtkBuilder .ui files. + + The command validates the .ui file and reports + errors to stderr. + + + The command lists all the named objects that + are created in the .ui file. + + + The command displays the .ui file. This command + accepts options to specify the ID of the toplevel object and a .css file + to use. + + + The command simplifies the .ui file by removing + properties that are set to their default values and writes the resulting XML + to stdout, or back to the input file. + + + When the is specified, + interprets the input as a GTK 3 ui file and attempts to convert it to GTK 4 + equivalents. It performs various conversions, such as renaming properties, + translating child properties to layout properties, rewriting the setup for + GtkNotebook, GtkStack, GtkAssistant or changing toolbars into boxes. + You should always test the modified .ui files produced by gtk4-builder-tool before using them in production. - - -Commands - The following commands are understood: - - - - Validates the .ui file and report errors to stderr. - - - - Simplifies the .ui file by removing properties that - are set to their default values and write the resulting XML to stdout, - or back to the input file. - - - - Lists all the named objects that are created in the .ui file. - - - - Preview the .ui file. This command accepts options - to specify the ID of an object and a .css file to use. - - + + Note in particular that the conversion + done with is meant as a starting point for a port + from GTK 3 to GTK 4. It is expected that you will have to do manual fixups + after the initial conversion. + Simplify Options -- 2.30.2